<div class="page-body">
    <a class="btn btn-default purple" href="{:U('add')}" style="margin-bottom: 15px;"><i class="fa fa-plus"></i>
        创建书包
    </a>
    <div class="row">
        <div class="col-xs-12 col-md-12">
            <div class="widget">
                <div class="widget-header ">
                    <span class="widget-caption">书包库</span>
                    <div class="widget-buttons">
                        <a href="#" data-toggle="maximize">
                            <i class="fa fa-expand"></i>
                        </a>
                        <a href="#" data-toggle="collapse">
                            <i class="fa fa-minus"></i>
                        </a>
                        <a href="#" data-toggle="dispose">
                            <i class="fa fa-times"></i>
                        </a>
                    </div>
                </div>
                <div class="widget-body">
                    <div class="table-toolbar">
                        <form method="get" action="{:U('index')}" class="form-inline" role="form">
                            <div class="form-group">
                                <span class="input-icon" style="width: 200px;">
                                    <input type="text" class="form-control input-sm" placeholder="书包编号"
                                           name="keywords">
                                    <i class="glyphicon glyphicon-search blue"></i>
                                </span>
                                <button type="submit" class="btn btn-info">搜索</button>


                            </div>
                        </form>
                    </div>
                    <table class="table table-striped table-hover">
                        <thead>
                        <tr>
                            <th>
                                ID
                            </th>
                            <th>
                                书包编号(唯一)
                            </th>
                            <th>
                                书包名称
                            </th>
                            <th>
                                操作
                            </th>
                        </tr>
                        </thead>

                        <tbody>
                        <foreach name="bagdata" item="v">
                            <tr>
                                <td>
                                    {$v.bag_id}
                                </td>
                                <td>
                                    {$v.bag_card}
                                </td>
                                <td>
                                    {$v.bag_name}
                                </td>
                                <td>
                                    <a class="btn btn-danger btn-xs del-btn"
                                       data-href="{:U('del',array('bag_id'=>$v['bag_id']))}"><i
                                            class="fa fa-trash-o"></i>删除</a>
                                    <a class="btn btn-info btn-xs"
                                       href="{:U('bind',array('bag_id'=>$v['bag_id']))}">
                                        <i class="fa fa-edit"></i> 绑定学生
                                    </a>
                                    <a class="btn btn-info btn-xs"
                                       href="{:U('edit',array('bag_id'=>$v['bag_id']))}">
                                        <i class="fa fa-edit"></i> 修改名称
                                    </a>
                                    <a class="btn btn-info btn-xs"
                                       href="{:U('booklist',array('bag_id'=>$v['bag_id']))}">
                                        <i class="fa fa-edit"></i> 查看图书
                                    </a>
                                </td>
                            </tr>
                        </foreach>
                        </tbody>
                    </table>
                    {$page}
                </div>
            </div>
        </div>
    </div>
</div>